import 'package:flutter_base/common/utils/utils.dart';
import 'package:flutter_base/global.dart';
import 'package:flutter/material.dart';

class MePage extends StatefulWidget {
  @override
  _MePageState createState() => _MePageState();
}

class _MePageState extends State<MePage> {
  @override
  Widget build(BuildContext context) {
    return Scaffold(
      backgroundColor: Colors.white,
      body: SafeArea(
        child: Container(
          color: Colors.grey[100],
          child: ListView(
            children: [
              Container(
                color: Colors.white,
                height: zhiSetHeight(20),
              ),
              Container(
                color: Colors.white,
                child: Row(
                  crossAxisAlignment: CrossAxisAlignment.center,
                  children: [
                    Container(
                      width: zhiSetWidth(60),
                      height: zhiSetWidth(60),
                      margin: EdgeInsets.all(zhiSetWidth(20)),
                      //边框设置
                      decoration: new BoxDecoration(
                        //背景
                        color: Colors.blueAccent,
                        //设置四周圆角 角度
                        borderRadius: BorderRadius.all(Radius.circular(10.0)),
                      ),
                      child: Center(
                        child: Text(
                          nickName('userName'),
                          style: TextStyle(
                              color: Colors.white, fontWeight: FontWeight.w500, fontSize: 20),
                        ),
                      ),
                    ),
                    Expanded(
                      child: Column(
                        crossAxisAlignment: CrossAxisAlignment.start,
                        children: [
                          Text(
                            'userName',
                            style: TextStyle(fontSize: 20, fontWeight: FontWeight.w500),
                          ),
                          Text(
                            'deptName',
                            style: TextStyle(color: Colors.grey),
                          ),
                        ],
                      ),
                    ),
                    Container(
                      margin: EdgeInsets.all(zhiSetWidth(20)),
                      child: Icon(
                        Iconfont.setting,
                        color: Colors.grey,
                      ),
                    )
                  ],
                ),
              ),
              Container(
                color: Colors.white,
                height: zhiSetHeight(10),
              ),
              Container(height: 10,),
              Container(
                color: Colors.white,
                child: ListTile(

                  leading: Container(
                    margin: EdgeInsets.all(zhiSetWidth(8)),
                    child: Icon(
                      Iconfont.shenqingshenpi,
                      color: Colors.blueAccent,
                    ),
                  ),
                  title: Text('申请审批'),
                  trailing: Container(
                    margin: EdgeInsets.all(zhiSetWidth(8)),
                    child: Icon(
                      Icons.arrow_forward_ios_rounded,
                      color: Colors.grey,
                      size: 16,
                    ),
                  ),
                ),
              ),
              Container(height: 10,),
              Container(
                color: Colors.white,
                child: ListTile(

                  leading: Container(
                    margin: EdgeInsets.all(zhiSetWidth(8)),
                    child: Icon(
                      Iconfont.daibanyiban,
                      color: Colors.blueAccent,
                    ),
                  ),
                  title: Text('待办已办'),
                  trailing: Container(
                    margin: EdgeInsets.all(zhiSetWidth(8)),
                    child: Icon(
                      Icons.arrow_forward_ios_rounded,
                      color: Colors.grey,
                      size: 16,
                    ),
                  ),
                ),
              ),
              Container(height: 10,),
              Container(
                color: Colors.white,
                child: ListTile(

                  leading: Container(
                    margin: EdgeInsets.all(zhiSetWidth(8)),
                    child: Icon(
                      Iconfont.kuaijiecaidan,
                      color: Colors.blueAccent,
                    ),
                  ),
                  title: Text('快捷菜单'),
                  trailing: Container(
                    margin: EdgeInsets.all(zhiSetWidth(8)),
                    child: Icon(
                      Icons.arrow_forward_ios_rounded,
                      color: Colors.grey,
                      size: 16,
                    ),
                  ),
                ),
              ),
              Container(height: 10,),
              Container(
                color: Colors.white,
                child: ListTile(

                  leading: Container(
                    margin: EdgeInsets.all(zhiSetWidth(8)),
                    child: Icon(
                      Iconfont.kuaidi,
                      color: Colors.blueAccent,
                    ),
                  ),
                  title: Text('快递信息'),
                  trailing: Container(
                    margin: EdgeInsets.all(zhiSetWidth(8)),
                    child: Icon(
                      Icons.arrow_forward_ios_rounded,
                      color: Colors.grey,
                      size: 16,
                    ),
                  ),
                ),
              ),
              Container(height: 10,),
              Container(
                color: Colors.white,
                child: ListTile(

                  leading: Container(
                    margin: EdgeInsets.all(zhiSetWidth(8)),
                    child: Icon(
                      Iconfont.danwei,
                      color: Colors.blueAccent,
                    ),
                  ),
                  title: Text('单位信息'),
                  trailing: Container(
                    margin: EdgeInsets.all(zhiSetWidth(8)),
                    child: Icon(
                      Icons.arrow_forward_ios_rounded,
                      color: Colors.grey,
                      size: 16,
                    ),
                  ),
                ),
              ),
              Container(height: 10,),
              Container(
                color: Colors.white,
                child: ListTile(

                  leading: Container(
                    margin: EdgeInsets.all(zhiSetWidth(8)),
                    child: Icon(
                      Iconfont.pinglun,
                      color: Colors.blueAccent,
                    ),
                  ),
                  title: Text('评论信息'),
                  trailing: Container(
                    margin: EdgeInsets.all(zhiSetWidth(8)),
                    child: Icon(
                      Icons.arrow_forward_ios_rounded,
                      color: Colors.grey,
                      size: 16,
                    ),
                  ),
                ),
              ),

            ],
          ),
        ),
      ),
    );
  }
}
